package com.zml.pdf.service;


import com.zml.pdf.entity.Pdfs;
import com.zml.pdf.mapper.PdfMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class PdfServiceImpl implements PdfService {

    @Autowired
    private PdfMapper pdfMapper;

    @Override
    public List<Pdfs> getPdf() {
        return pdfMapper.getPdf();
    }

    @Override
    public Pdfs getPdfById(String id) {
        return pdfMapper.getPdfById(id);
    }

    @Override
    public Pdfs getPdfByName(String name) {
        return pdfMapper.getPdfByName(name);
    }

    @Override
    public String getAESkey() {
//        String aeSkey = pdfMapper.getAESkey();
//        System.out.println(aeSkey);
        return "";
    }

    @Override
    public void insertPdf(Pdfs pdfs) {
        pdfMapper.insertPdf(pdfs);
    }

    @Override
    public void deletePdf(String id) {
        pdfMapper.deletePdf(id);
    }


}
